package com.crm.jdy.common.dto;

import com.baomidou.mybatisplus.annotation.*;
import com.crm.jdy.common.vo.PageVO;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonIgnore;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.springframework.format.annotation.DateTimeFormat;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.io.Serializable;
import java.util.Date;

@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
public class ClientInvoiceInfoDto extends PageVO implements Serializable {

    private static final long serialVersionUID = 16167264829L;

    @TableId(value = "invoice_id", type = IdType.ID_WORKER_STR)
    @ApiModelProperty(name = "invoiceId" , value = "发票主键id")
    private String invoiceId;

    @NotBlank(message = "发票客户名称非空")
    @ApiModelProperty(name = "invoiceName" , value = "发票客户名称")
    private String invoiceName;

    @NotNull(message = "合同编号不为空")
    @ApiModelProperty(name = "invoiceContractid" , value = "合同编号")
    private String invoiceContractid;

    @ApiModelProperty(name = "invoiceContractMoney" , value = "合同金额")
    private String invoiceContractMoney;

    @ApiModelProperty(name = "invoiceMoney" , value = "开票金额")
    private String invoiceMoney;


    @ApiModelProperty(name = "invoiceTime" , value = "开票日期")
    private String invoiceTime;

    @ApiModelProperty(name = "invoiceActualTime" , value = "实际开票日期")
    private String invoiceActualTime;

    @ApiModelProperty(name = "invoiceType" , value = "开票类型")
    private String invoiceType;

    @NotNull(message = "发票号码不为空")
    @ApiModelProperty(name = "invoiceNumber" , value = "发票号码")
    private String invoiceNumber;

    @ApiModelProperty(name = "invoiceLogisticsid" , value = "物流号码")
    private String invoiceLogisticsid;

    @ApiModelProperty(name = "invoiceChargePerson" , value = "负责人")
    private String invoiceChargePerson;

    @ApiModelProperty(name = "invoiceStatus" , value = "审核状态")
    private String invoiceStatus;

    @JsonIgnore
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern="yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @ApiModelProperty(name = "createTime" , value = "创建时间")
    @TableField(fill = FieldFill.INSERT)
    private Date createTime;

    @JsonIgnore
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern="yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    @ApiModelProperty(name = "updateTime" , value = "更新最新时间")
    @TableField(fill = FieldFill.INSERT_UPDATE)
    private Date updateTime;

    @JsonIgnore
    @TableLogic
    @ApiModelProperty(name = "isDelete" , value = "0正常  1删除")
    private Integer isDelete;

}
